<script>
import VueRouter from "vue-router";
import Home from "../pages/Home";
import Error from "../pages/Error";
import Login from "../pages/account/login.vue";

const routes = [
    {
        path: "/",
        component: Login,
        meta: {
            title: "登录",
        },
    },
    {
        path: "/home",
        component: Home,
        meta: {
            title: "首页",
        },
    },
    {
        path: "*",
        component: Error,
        meta: {
            title: "404",
        },
    },
];

const router = new VueRouter({
    mode: "history",
    base: "/template/",
    routes,
});

export default router;
</script>
